﻿/*
 * -------------------------------------------------------------------------------
 * 版权信息：		 
 * 功能描述：	代码处成器生成
 * 
 * 创建人：　	代码生成
 * 创建日期：	2021-04-21 12:40:50
 * 创建说明：	
 * 
 * 修改人：　	
 * 修改日期：	
 * 修改说明：	
 *    
 * -------------------------------------------------------------------------------
 */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using MS.Entities;
using MS.DataAccess;

namespace MS.Logic
{
    public partial class MS_UserCenter_UserAttrLogic
    {
        private MS_UserCenter_UserAttrDataAccess ms_UserCenter_UserAttrDal = new MS_UserCenter_UserAttrDataAccess();

        private static MS_UserCenter_UserAttrLogic _MS_UserCenter_UserAttrLogic = null;
        private MS_UserCenter_UserAttrLogic()
        {

        }
        /// <summary>
        /// 获得一个单体实例
        /// </summary>
        /// <returns></returns>
        public static MS_UserCenter_UserAttrLogic GetInstance()
        {
            if(_MS_UserCenter_UserAttrLogic == null)
            {
                _MS_UserCenter_UserAttrLogic = new MS_UserCenter_UserAttrLogic();
            }
            return _MS_UserCenter_UserAttrLogic;
        }

        /// <summary>
        /// 用户属性表-增加方法
        /// </summary>
        public void Add(MS_UserCenter_UserAttr ms_UserCenter_UserAttr)
        {
            ms_UserCenter_UserAttrDal.Add(ms_UserCenter_UserAttr);
        }

        /// <summary>
        /// 用户属性表-删除方法
        /// </summary>
        public void Remove(long uid)
        {
            ms_UserCenter_UserAttrDal.Remove(uid);
        }

        /// <summary>
        /// 用户属性表-删除方法
        /// </summary>
        public void Remove(Expression<Func<MS_UserCenter_UserAttr, bool>> condition)
        {
            ms_UserCenter_UserAttrDal.Remove(condition);
        }

        /// <summary>
        /// 用户属性表-修改方法
        /// </summary>
        public void Save(MS_UserCenter_UserAttr ms_UserCenter_UserAttr)
        {
            ms_UserCenter_UserAttrDal.Save(ms_UserCenter_UserAttr);
        }

        /// <summary>
        /// 用户属性表-根据主键获取实体信息
        /// </summary>
        /// <returns></returns>
		public MS_UserCenter_UserAttr GetById(long uid)
        {
            return ms_UserCenter_UserAttrDal.GetById(uid);
        }

		        /// <summary>
        /// 用户属性表-根据查询条件获取实体信息
        /// <param name="condition">查询条件</param>
        /// </summary>
        /// <returns></returns>
        public MS_UserCenter_UserAttr GetItemByQuery(Expression<Func<MS_UserCenter_UserAttr, bool>> condition)
        {
			return ms_UserCenter_UserAttrDal.GetItemByQuery(condition);
		}

        /// <summary>
        /// 用户属性表-根据条件查询是否存在
        /// <param name="condition">查询条件</param>
        /// </summary>
        /// <returns></returns>
        public bool IsExists(Expression<Func<MS_UserCenter_UserAttr, bool>> condition)
        {
            return ms_UserCenter_UserAttrDal.IsExists(condition);
        }

		/// <summary>
        /// 用户属性表-根据查询条件获取总数
        /// <param name="condition">查询条件</param>
        /// </summary>
        /// <returns></returns>
        public int GetCountByQuery(Expression<Func<MS_UserCenter_UserAttr, bool>> condition)
        {
			return ms_UserCenter_UserAttrDal.GetCountByQuery(condition);
		}

        /// <summary>
        /// 用户属性表-获取所有
        /// </summary>
        /// <returns></returns>
        public List<MS_UserCenter_UserAttr> GetAll()
        {
            return ms_UserCenter_UserAttrDal.GetAll();
        }

        /// <summary>
        /// 用户属性表-分页查询
        /// </summary>
        /// <param name="startRowIndex">索引开始</param>
        /// <param name="maximumRows">每页信息条数</param>
        /// <param name="condition">查询条件</param>
        /// <param name="totalRecords">总计录数</param>
		/// <param name="orderBy">排序条件</param>
        /// <param name="isDesc">是否倒序</param>
        /// <returns></returns>
        public List<MS_UserCenter_UserAttr> GetPagedList(int startRowIndex, int maximumRows,Expression<Func<MS_UserCenter_UserAttr,bool>> condition, string orderBy, bool isDesc, out int totalRecords)
        {
            return ms_UserCenter_UserAttrDal.GetPagedList(startRowIndex, maximumRows,condition, orderBy, isDesc, out totalRecords);
        }

				/// <summary>
        /// 用户属性表-分页查询
        /// </summary>
        /// <param name="startRowIndex">索引开始</param>
        /// <param name="maximumRows">每页信息条数</param>
        /// <param name="condition">查询条件</param>
        /// <param name="totalRecords">总计录数</param>
		/// <param name="orderBy">排序条件</param>
        /// <param name="isDesc">是否倒序</param>
        /// <returns></returns>
		public List<MS_UserCenter_UserAttr> GetPagedListExpression(int startRowIndex, int maximumRows, Expression<Func<MS_UserCenter_UserAttr,bool>> condition, Expression<Func<MS_UserCenter_UserAttr, object>> orderBy, bool isDesc, out int totalRecords)
        {
			return ms_UserCenter_UserAttrDal.GetPagedListExpression(startRowIndex, maximumRows,condition, orderBy, isDesc, out totalRecords);
		}

		/// <summary>
        /// 用户属性表-根据条件查询
        /// </summary>
        /// <param name="condition">条件</param>
        /// <param name="orderBy">排序条件</param>
        /// <param name="isDesc">是否倒序</param>
        /// <returns></returns>
        public List<MS_UserCenter_UserAttr> GetListByQuery(Expression<Func<MS_UserCenter_UserAttr, bool>> condition, string orderBy, bool isDesc)
        {
			return ms_UserCenter_UserAttrDal.GetListByQuery(condition, orderBy, isDesc);
		}

				/// <summary>
        /// 用户属性表-根据条件查询
        /// </summary>
        /// <param name="condition">条件</param>
        /// <param name="orderBy">排序条件</param>
        /// <param name="isDesc">是否倒序</param>
        /// <returns></returns>
        public List<MS_UserCenter_UserAttr> GetListByQueryExpression(Expression<Func<MS_UserCenter_UserAttr, bool>> condition, Expression<Func<MS_UserCenter_UserAttr, object>> orderBy, bool isDesc)
        {
			return ms_UserCenter_UserAttrDal.GetListByQueryExpression(condition, orderBy, isDesc);
		}

    }
}
